// 入口文件
import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import './lib/mui/css/mui.min.css'
import './lib/mui/css/icons-extra.css'
// 按需导入mint-ui 的组件
import { Header, Swipe, SwipeItem, Button } from 'mint-ui'
import Axios from 'axios'
// 将axios绑定在 Vue的原型上，这样可以在其他组件中使用axios
Vue.prototype.$axios = Axios

Vue.component(Header.name, Header)
Vue.component(Swipe.name, Swipe)
Vue.component(SwipeItem.name, SwipeItem)
Vue.component(Button.name, Button)
Vue.config.productionTip = false

import moment from 'moment'
Vue.filter('dateFormat', function (dataStr, pattern = "YYYY-MM-DD HH:mm:ss") {
  return moment(dataStr).format(pattern)
})
new Vue({
  router,
  store,
  Axios,
  render: h => h(App)
}).$mount('#app')
